<?php

class Index_Model extends Model {

    public function __construct() {
        parent::__construct();
    }
    
    public function getAllCategories()
    {
        $arr = $this -> db -> select('SELECT * FROM category');
        return json_encode($arr);
    }
    
     public function getAllItemsByDate()
    {
        $arr = $this -> db -> select('SELECT * FROM item ORDER BY date DESC');
        return json_encode($arr);
    }
    
    public function submit_step1()
    {
        
    }
}
